<?php
namespace core\tv\validate;

use core\Validate;

class VideoValidate extends Validate
{

    /**
     * 规则
     *
     * @var unknown
     */
    protected $rule = [
        'video_name' => 'require',
        'cate_id' => 'require',
        'cover' => 'require',
        'preview' => 'require'
    ];

    /**
     * 提示
     *
     * @var unknown
     */
    protected $message = [
        'video_name.require' => '视频名称为空',
        'cate_id.require' => '视频分类为空',
        'cover.require' => '视频封面为空',
        'preview.require' => '视频预览GIF图为空'
    ];

    /**
     * 场景
     *
     * @var unknown
     */
    protected $scene = [
        'add' => [
            'video_name',
            'cate_id',
            'cover',
            'preview'
        ],
        'edit' => [
            'video_name',
            'cate_id',
            'cover',
            'preview'
        ]
    ];
}